package com.taylover.test.animal;

/**
 * @author xyzZero3
 * @date 2025/4/9 22:01
 */
public class Fish extends Animal implements Pet{

    private String name;

    @Override
    public void walk() {
        System.out.println("鱼不能走且没有腿");
    }

    public Fish() {
        super(0);
    }

    @Override
    public void eat() {
        System.out.println("小鱼吃饭");
    }

    @Override
    public String getName() {
        return this.name;
    }

    @Override
    public void setName(String name) {
        this.name = name;
    }

    @Override
    public void play() {
        System.out.println("小鱼玩游戏");
    }
}
